<?php
    $db->remove("gallery_picture", "id='$id'");

    redirect("index.php?gid=$gid");
?>